/*
 * @(#)TaskDurationPropertySection.java.java        0.00 2008/01/05
 */
package jp.ekasi.pms.ui.properties.tabbed.section;

import java.text.NumberFormat;

import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.nebula.widgets.formattedtext.ITextFormatter;
import org.eclipse.nebula.widgets.formattedtext.NumberFormatter;

import jp.ekasi.pms.model.ModelPackage;
import jp.ekasi.pms.ui.properties.tabbed.common.section.AbstractFormatedTextPropertySection;

/**
 * @author Yuusuke Hikime
 */
public class TaskDurationPropertySection extends
		AbstractFormatedTextPropertySection {

	@Override
	public ITextFormatter getTextFormatter() {
		return new NumberFormatter("###,###,##0.0");
	}

	@Override
	protected EAttribute getFeature() {
		return ModelPackage.Literals.TASK__DURATION;
	}
	
	@Override
	protected Object getFeatureValue(String newText) {
		return new Double(newText);
	}
}
